package com.cyp.demo04;

import com.cyp.demo01.Proxy;
import com.cyp.demo02.UserService;
import com.cyp.demo02.UserServiceImpl;



public class Client {
    public static void main(String[] args) {
        UserServiceImpl userService = new UserServiceImpl();

        ProxyInvocationHandler pih = new ProxyInvocationHandler();
        pih.setTarget(userService);

        UserService proxy = (UserService)pih.getProxy();

        proxy.select();
    }
}
